package tech.aistar.controller;

import org.springframework.stereotype.Controller;
import org.springframework.web.bind.annotation.GetMapping;
import org.springframework.web.bind.annotation.RequestMapping;
import org.springframework.web.bind.annotation.ResponseBody;
import org.springframework.web.bind.annotation.RestController;

/**
 * 本类用来演示:
 *
 * @author: success
 * @date: 2021/4/29 9:20 上午
 */
//@Controller
//@ResponseBody
@RestController //@RestController = @Controller + @ResponseBody
@RequestMapping("/rest")
public class RestControllerAction {

    @GetMapping("/test01")
    //@ResponseBody
    public String test01(){
        return "test01";
    }

    @GetMapping("/test02")
    //@ResponseBody
    public String test02(){
        return "test02";
    }
}
